package com.information.manage.basic.common.utils.exportAndImport.constant;

/**
 * 表格颜色枚举
 * @see https://blog.csdn.net/shanghaojiabohetang/article/details/51837242
 */
public enum ColorEnum {

    BLACK("8", "黑色"),
    WHITE("9", "白色"),
    RED("10", "红色"),
    BRIGHT_GREEN("11", "亮绿色"),
    BLUE("12", "蓝色"),
    YELLOW("13", "黄色"),
    PINK("14", "粉红色"),
    TURQUOISE("15", "绿松石"),
    DARK_RED("16", "深红色"),
    GREEN("17", "绿色"),
    DARK_BLUE("18", "深蓝色"),
    DARK_YELLOW("19", "深黄色"),
    VIOLET("20", "紫罗兰"),
    TEAL("21", "青色"),
    GREY_25_PERCENT("22", "灰色25%"),
    GREY_50_PERCENT("23", "灰色50%"),
    CORNFLOWER_BLUE("24", "矢车菊蓝"),
    LEMON_CHIFFON("26", "柠檬雪纺"),
    ORCHID("28", "兰花"),
    CORAL("29", "珊瑚"),
    ROYAL_BLUE("30", "皇家蓝"),
    LIGHT_CORNFLOWER_BLUE("31", "浅色玉米花蓝色"),
    SKY_BLUE("40", "天蓝色"),
    LIGHT_TURQUOISE("41", "浅绿松石"),
    LIGHT_GREEN("42", "浅绿色"),
    LIGHT_YELLOW("43", "浅黄色"),
    PALE_BLUE("44", "淡蓝色"),
    ROSE("45", "粉红色"),
    LAVENDER("46", "淡紫色"),
    TAN("47", "棕褐色"),
    LIGHT_BLUE("48", "淡蓝色"),
    AQUA("49", "浅绿色"),
    LIME("50", "绿黄色"),
    GOLD("51", "金色"),
    LIGHT_ORANGE("52", "浅橙色"),
    ORANGE("53", "橙色"),
    BLUE_GREY("54", "蓝灰色"),
    GREY_40_PERCENT("55", "灰色40%"),
    DARK_TEAL("56", "深青色"),
    SEA_GREEN("57", "海绿"),
    DARK_GREEN("58", "深绿"),
    OLIVE_GREEN("59", "橄榄绿"),
    BROWN("60", "棕色"),
    PLUM("61", "紫红色"),
    INDIGO("62", "靛蓝"),
    GREY_80_PERCENT("63", "灰色80%")
    ;

    public short index;

    public String description;

    ColorEnum(String index, String description){
        this.index = Short.valueOf(index);
        this.description = description;
    }

    public static ColorEnum getInstance(short index){
        for (ColorEnum value : ColorEnum.values()) {
            if (index == value.index){
                return value;
            }
        }
        return null;
    }

}
